package com.laotou99.test2;

import java.util.HashMap;
import java.util.UUID;
import java.util.concurrent.ConcurrentMap;

import com.google.common.cache.Cache;
import com.google.common.cache.CacheBuilder;
import com.google.common.collect.Maps;

public class Test4 {

	public static void main(String[] args) {
		test1();
		test2();
		//UUID u1 = UUID.fromString("3451");
		//System.out.println(u1.toString());
		
		System.out.println(getUUID32());
		
	}

	private static void test2() {
		HashMap<String, Object> newHashMap = Maps.newHashMap();
		
	}

	private static void test1() {
		
		CacheBuilder<Object, Object> newBuilder = CacheBuilder.newBuilder(); 
		Cache<String, Object> build1 = newBuilder.build();
		build1.put("abc", "eee");
		
		ConcurrentMap<String, Object> mm1 = build1.asMap();
		Object o1 = mm1.get("abc");
		System.out.println(""+o1);
	}

	public static String getUUID32(){
	    String uuid = UUID.randomUUID().toString().replace("-", "").toUpperCase();
	    return uuid;
	//  return UUID.randomUUID().toString().replace("-", "").toLowerCase();
	}
}
